package com.wtwd.campus.jdzc.service.impl;

import com.wtwd.campus.entity.DeviceSetting;
import com.wtwd.campus.jdzc.dao.JdzcDeviceSettingMapper;
import com.wtwd.campus.jdzc.service.JdbcDeviceSettingService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class JdzcDeviceSettingServiceImpl implements JdbcDeviceSettingService {

    @Autowired
    private JdzcDeviceSettingMapper jdzcDeviceSettingMapper;

    @Override
    public DeviceSetting getDeviceSettingByImei(String imei) {
        return jdzcDeviceSettingMapper.getDeviceSettingByImei(imei);
    }

    @Override
    public Integer modifyDeviceSetting(DeviceSetting deviceSetting) {
        return jdzcDeviceSettingMapper.modifyDeviceSetting(deviceSetting);
    }

    @Override
    public DeviceSetting getDeviceSettingByDeviceId(Integer deviceId) {
        return jdzcDeviceSettingMapper.getDeviceSettingByDeviceId(deviceId);
    }

    @Override
    public int modifySilentSwitchByDeviceId(Integer deviceId, Integer flag) {
        return jdzcDeviceSettingMapper.modifySilentSwitchByDeviceId(deviceId, flag);
    }
}
